cmake_minimum_required(VERSION 3.4.1)

add_library(keys SHARED
        keys.c)

add_library(key_util SHARED
        util/string_util.c
        file/android_fopen.c
        util/key_util.c)

add_library(patch SHARED
        bzip2/blocksort.c
        bzip2/bzip2.c
        bzip2/bzip2recover.c
        bzip2/bzlib.c
        bzip2/compress.c
        bzip2/crctable.c
        bzip2/decompress.c
        bzip2/dlltest.c
        bzip2/huffman.c
        bzip2/mk251.c
        bzip2/randtable.c
        bzip2/spewG.c
        bzip2/unzcrash.c
        bspatch.c)

target_link_libraries(keys
        log)

target_link_libraries(key_util
        android)